Skip to content

Sanitizers target modificators #138736

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

azhogin
Copy link
Contributor

@azhogin azhogin commented Mar 20, 2025

Depends on bool flag fix: #138483.

Some sanitizers need to be target modifiers, and some do not. For now, we should mark all sanitizers as target modifiers except for these: AddressSanitizer, LeakSanitizer

For kCFI, the helper flag -Zsanitizer-cfi-normalize-integers should also be a target modifier.

Many test errors was with sanizer flags inconsistent with std deps. Tests are fixed with -C unsafe-allow-abi-mismatch.

@rustbot
Copy link
Collaborator

rustbot commented Mar 20, 2025

r? @BoxyUwU

rustbot has assigned @BoxyUwU.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Mar 20, 2025
@rust-log-analyzer

This comment has been minimized.

@azhogin azhogin force-pushed the azhogin/sanitizers-target-modificators branch from 7526d38 to 0777169 Compare March 20, 2025 12:59
@rust-log-analyzer

This comment has been minimized.

@azhogin azhogin force-pushed the azhogin/sanitizers-target-modificators branch from 0777169 to f454b02 Compare March 24, 2025 08:53
@rustbot rustbot added the PG-exploit-mitigations Project group: Exploit mitigations label Mar 24, 2025
@rust-log-analyzer

This comment has been minimized.

@azhogin azhogin force-pushed the azhogin/sanitizers-target-modificators branch from f454b02 to 509e0b3 Compare March 24, 2025 09:37
@rust-log-analyzer

This comment has been minimized.

@azhogin azhogin force-pushed the azhogin/sanitizers-target-modificators branch from 509e0b3 to 1f20a51 Compare March 24, 2025 11:33
@rust-log-analyzer

This comment has been minimized.

@azhogin azhogin force-pushed the azhogin/sanitizers-target-modificators branch from 1f20a51 to fc95e77 Compare March 24, 2025 13:14
@rust-log-analyzer

This comment has been minimized.

@azhogin azhogin force-pushed the azhogin/sanitizers-target-modificators branch 2 times, most recently from e025a55 to c54dcfc Compare March 24, 2025 13:40
@azhogin azhogin marked this pull request as ready for review March 24, 2025 14:46
@rustbot
Copy link
Collaborator

rustbot commented Mar 24, 2025

Some changes occurred in tests/codegen/sanitizer

cc @rust-lang/project-exploit-mitigations, @rcvalle

Some changes occurred in tests/ui/sanitizer

cc @rust-lang/project-exploit-mitigations, @rcvalle

@bors
Copy link
Collaborator

bors commented Mar 26, 2025

☔ The latest upstream changes (presumably #138974) made this pull request unmergeable. Please resolve the merge conflicts.

@BoxyUwU
Copy link
Member

BoxyUwU commented Mar 26, 2025

r? compiler

@Darksonn
Copy link
Contributor

Do we have any tests that check simultaneous use of multiple sanitizers? For example, if I enable both shadow-call-stack and kcfi at the same time, then both must also be enabled in deps.

@rcvalle rcvalle added the A-sanitizers Area: Sanitizers for correctness and code quality label Apr 10, 2025
@rcvalle
Copy link
Member

rcvalle commented Apr 10, 2025

@rustbot claim

@rustbot rustbot assigned rcvalle and unassigned oli-obk Apr 10, 2025
@@ -0,0 +1,7 @@
//@ no-prefer-dynamic
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: Should test file names be separated by hyphen ('-') instead?

@rcvalle
Copy link
Member

rcvalle commented Apr 15, 2025

Do we have any tests that check simultaneous use of multiple sanitizers? For example, if I enable both shadow-call-stack and kcfi at the same time, then both must also be enabled in deps.

Unfortunately, I don't think we do at this moment. (Others feel free to correct me if I'm wrong.) Something somewhat related that I also wanted us to have that we don't at the moment is build core and std and run their tests with some sanitizers enabled, such as CFI to make sure they currently work and no regressions/explicit CFI violations are introduced.

@azhogin azhogin force-pushed the azhogin/sanitizers-target-modificators branch from c54dcfc to 3d27c96 Compare April 27, 2025 20:34
@azhogin
Copy link
Contributor Author

azhogin commented Apr 27, 2025

Renamed '_' to '-' in tests, added test with safestack + kcfi sanitizers. Btw, which target supports both kcfi and shadow-call-stack in the example?

About core/std build with sanitizers - I am not sure, how to integrate it to the current test system. Won't it be an overkill to build several versions of core/std in test procedure?

@rust-log-analyzer

This comment has been minimized.

…t modifiers with custom consistency check function
@azhogin azhogin force-pushed the azhogin/sanitizers-target-modificators branch from 3d27c96 to 280dfab Compare April 27, 2025 21:08
@rcvalle
Copy link
Member

rcvalle commented May 7, 2025

Renamed '_' to '-' in tests, added test with safestack + kcfi sanitizers. Btw, which target supports both kcfi and shadow-call-stack in the example?

Thank you for working on this! Much appreciated. AFAIK, the closest is aarch64_linux_android, which supports ShadowCallStack and CFI (not KCFI, but most of the implementation is shared). I think @Darksonn was referring more generally about testing sanitizers that should be compatible or possible to be used together (which I think we should do as well).

About core/std build with sanitizers - I am not sure, how to integrate it to the current test system. Won't it be an overkill to build several versions of core/std in test procedure?

No worries. This was not meant to be implemented in this PR. I've started a conversation on Zulip so we could discuss and plan this: #t-infra > Running core and std tests with sanitizers. Let me know if you are interested in helping out with it.

@rcvalle
Copy link
Member

rcvalle commented May 7, 2025

@bors r+

@bors
Copy link
Collaborator

bors commented May 7, 2025

📌 Commit 280dfab has been approved by rcvalle

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels May 7, 2025
Zalathar added a commit to Zalathar/rust that referenced this pull request May 8, 2025
…modificators, r=rcvalle

Sanitizers target modificators

Depends on bool flag fix: rust-lang#138483.

Some sanitizers need to be target modifiers, and some do not. For now, we should mark all sanitizers as target modifiers except for these: AddressSanitizer, LeakSanitizer

For kCFI, the helper flag -Zsanitizer-cfi-normalize-integers should also be a target modifier.

Many test errors was with sanizer flags inconsistent with std deps. Tests are fixed with `-C unsafe-allow-abi-mismatch`.
bors added a commit to rust-lang-ci/rust that referenced this pull request May 8, 2025
Rollup of 15 pull requests

Successful merges:

 - rust-lang#138736 (Sanitizers target modificators)
 - rust-lang#140260 (Only prefer param-env candidates if they remain non-global after norm)
 - rust-lang#140523 (Better error message for late/early lifetime param mismatch)
 - rust-lang#140579 (Remove estebank from automated review assignment)
 - rust-lang#140641 (detect additional uses of opaques after writeback)
 - rust-lang#140711 (Do not discard constraints on overflow if there was candidate ambiguity)
 - rust-lang#140716 (Improve `-Zremap-path-scope` tests with dependency)
 - rust-lang#140755 ([win][arm64] Disable various DebugInfo tests that don't work on Arm64 Windows)
 - rust-lang#140756 ([arm64] Pointer auth test should link with C static library statically)
 - rust-lang#140758 ([win][arm64] Disable MSVC Linker 'Arm Hazard' warning)
 - rust-lang#140759 ([win][arm64] Disable std::fs tests that require symlinks)
 - rust-lang#140762 (rustdoc-json: Remove newlines from attributes)
 - rust-lang#140764 (style: Never break within a nullary function call `func()` or a unit literal `()`)
 - rust-lang#140769 (Add `DefPathData::OpaqueLifetime` to avoid conflicts for remapped opaque lifetimes)
 - rust-lang#140773 (triagebot: Better message for changes to `tests/rustdoc-json`)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors
Copy link
Collaborator

bors commented May 8, 2025

⌛ Testing commit 280dfab with merge 63e001aa2571a1f582cfc7d689c35a80a34fadec...

bors added a commit to rust-lang-ci/rust that referenced this pull request May 8, 2025
…dificators, r=rcvalle

Sanitizers target modificators

Depends on bool flag fix: rust-lang#138483.

Some sanitizers need to be target modifiers, and some do not. For now, we should mark all sanitizers as target modifiers except for these: AddressSanitizer, LeakSanitizer

For kCFI, the helper flag -Zsanitizer-cfi-normalize-integers should also be a target modifier.

Many test errors was with sanizer flags inconsistent with std deps. Tests are fixed with `-C unsafe-allow-abi-mismatch`.
@rust-log-analyzer
Copy link
Collaborator

The job aarch64-apple failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)
test [ui] tests/ui/target_modifiers/sanitizer-kcfi-normalize-ints.rs#ok ... ignored, ignored on targets without kernel CFI sanitizer
test [ui] tests/ui/target_modifiers/sanitizer-kcfi-normalize-ints.rs#wrong_flag ... ignored, ignored on targets without kernel CFI sanitizer
test [ui] tests/ui/target_modifiers/sanitizer-kcfi-normalize-ints.rs#wrong_sanitizer ... ignored, ignored on targets without kernel CFI sanitizer
test [ui] tests/ui/target_modifiers/no_value_bool.rs#ok ... ok
test [ui] tests/ui/target_modifiers/sanitizers-good-for-inconsistency.rs#wrong_leak_san ... ignored, ignored on targets without leak sanitizer
test [ui] tests/ui/target_modifiers/sanitizers-safestack-and-kcfi.rs#good ... ignored, ignored on targets without SafeStack support
test [ui] tests/ui/target_modifiers/sanitizers-safestack-and-kcfi.rs#good_reverted ... ignored, ignored on targets without SafeStack support
test [ui] tests/ui/target_modifiers/sanitizers-safestack-and-kcfi.rs#missed_both ... ignored, ignored on targets without SafeStack support
test [ui] tests/ui/target_modifiers/sanitizers-safestack-and-kcfi.rs#missed_kcfi ... ignored, ignored on targets without SafeStack support
test [ui] tests/ui/target_modifiers/sanitizers-safestack-and-kcfi.rs#missed_safestack ... ignored, ignored on targets without SafeStack support
test [ui] tests/ui/target_modifiers/no_value_bool.rs#ok_explicit ... ok
test [ui] tests/ui/target_modifiers/sanitizers-good-for-inconsistency.rs#wrong_address_san ... ok
test [ui] tests/ui/target_modifiers/two_flags.rs#two_allowed ... ok
test [ui] tests/ui/target_modifiers/two_flags.rs#unknown_allowed ... ok
test [ui] tests/ui/test-attrs/custom-test-frameworks/issue-107454.rs ... ok
test [ui] tests/ui/test-attrs/decl-macro-test.rs ... ok
test [ui] tests/ui/test-attrs/inaccessible-test-modules.rs ... ok
---
---- [ui] tests/ui/sanitizer/thread.rs stdout ----

error: test compilation failed although it shouldn't!
status: exit status: 1
command: env -u RUSTC_LOG_COLOR RUSTC_ICE="0" RUST_BACKTRACE="short" "/Users/runner/work/rust/rust/build/aarch64-apple-darwin/stage2/bin/rustc" "/Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs" "-Zthreads=1" "-Zsimulate-remapped-rust-src-base=/rustc/FAKE_PREFIX" "-Ztranslate-remapped-path-to-local-path=no" "-Z" "ignore-directory-in-diagnostics-source-blocks=/Users/runner/.cargo" "-Z" "ignore-directory-in-diagnostics-source-blocks=/Users/runner/work/rust/rust/vendor" "--sysroot" "/Users/runner/work/rust/rust/build/aarch64-apple-darwin/stage2" "--target=aarch64-apple-darwin" "--check-cfg" "cfg(test,FALSE)" "--error-format" "json" "--json" "future-incompat" "-Ccodegen-units=1" "-Zui-testing" "-Zdeduplicate-diagnostics=no" "-Zwrite-long-types-to-disk=no" "-Cstrip=debuginfo" "-C" "prefer-dynamic" "-o" "/Users/runner/work/rust/rust/build/aarch64-apple-darwin/test/ui/sanitizer/thread/a" "-A" "unused" "-A" "internal_features" "-Crpath" "-Cdebuginfo=0" "-Lnative=/Users/runner/work/rust/rust/build/aarch64-apple-darwin/native/rust-test-helpers" "-Z" "sanitizer=thread" "-O"
stdout: none
--- stderr -------------------------------
error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `std`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `std`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `core`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `core`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `alloc`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `alloc`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `compiler_builtins`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `compiler_builtins`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `rustc_std_workspace_core`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `rustc_std_workspace_core`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `libc`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `libc`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `unwind`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `unwind`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `cfg_if`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `cfg_if`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `miniz_oxide`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `miniz_oxide`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `adler2`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `adler2`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `hashbrown`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `hashbrown`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `rustc_std_workspace_alloc`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `rustc_std_workspace_alloc`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `std_detect`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `std_detect`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `rustc_demangle`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `rustc_demangle`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `addr2line`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `addr2line`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `gimli`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `gimli`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `object`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `object`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `memchr`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `memchr`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: mixing `-Zsanitizer` will cause an ABI mismatch in crate `thread`
##[error]  --> /Users/runner/work/rust/rust/tests/ui/sanitizer/thread.rs:23:1
   |
LL | #![feature(rustc_private)]
   | ^
   |
   = help: the `-Zsanitizer` flag modifies the ABI so Rust crates compiled with different values of this flag cannot be used together safely
   = note: `-Zsanitizer=thread` in this crate is incompatible with unset `-Zsanitizer` in dependency `panic_unwind`
   = help: unset `-Zsanitizer` in this crate or set `-Zsanitizer=thread` in `panic_unwind`
   = help: if you are sure this will not cause problems, you may use `-Cunsafe-allow-abi-mismatch=sanitizer` to silence this error

error: aborting due to 19 previous errors
------------------------------------------


@bors
Copy link
Collaborator

bors commented May 8, 2025

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels May 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-sanitizers Area: Sanitizers for correctness and code quality PG-exploit-mitigations Project group: Exploit mitigations S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants